<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>Basic DataGrid - jQuery EasyUI Demo</title>
    <link rel="stylesheet" type="text/css"
          href="/plugin/jquery-easyui-1.4.5/themes/default/easyui.css">
    <link rel="stylesheet" type="text/css" href="/plugin/jquery-easyui-1.4.5/themes/icon.css">
    <script type="text/javascript" src="/plugin/jquery-easyui-1.4.5/jquery.min.js"></script>
    <script type="text/javascript" src="/plugin/jquery-easyui-1.4.5/jquery.easyui.min.js"></script>
</head>

<script type="text/javascript">
    $(function () {
        $('#dg').datagrid({
            url: '/admin/listdata',
            columns: [[
                {field: 'itemid', title: 'Code', width: 100},
                {field: 'productid', title: 'Name', width: 100},
                {field: 'attr1', title: 'Price', width: 100, align: 'right'}
            ]],
            pagination:true
        });
    });
</script>

<body>
<h2>Basic DataGrid</h2>

<p>The DataGrid is created from markup, no JavaScript code needed.</p>

<div style="margin:20px 0;"></div>
<table id="dg"></table>

</body>
</html>
